import Vue from "vue";
import VueRouter from "@/libs/my-vue-router";
import Home from "@/views/Home";
import About from "@/views/About";

// 插件注册
Vue.use(VueRouter);

export default new VueRouter({
  routes: [
    { path: "/home", component: Home },
    {
      path: "/about",
      component: About,
      children: [
        {
          path: "/about/news",
          component: { render(h) {return h('div', 'About news')} },
        },
      ],
    },
  ],
});
